<template>
  <div class="unpay">
    <el-table :data="tableData"
              stripe
              style="width: 100%"
    >
      <el-table-column prop="name"
                       label="店名"
                       width="180">
      </el-table-column>
      <el-table-column prop="time"
                       label="下单时间"
                       width="180">
      </el-table-column>
      <el-table-column prop="state"
                       label="当前状态"
                       width="180">
      </el-table-column>
      <el-table-column>
        <template>
          <el-button   @click="order()" style=" width:50%; margin-bottom:0px;">查看详情</el-button>
        </template>


      </el-table-column>
    </el-table>
    <el-container>
      <router-view></router-view>
    </el-container>
  </div>
</template>

<script>
export default {
  data() {
    //在进入之前先从后台获取信息
    return {
      tableData: [{
        name: '41261432215',
        time: '12:29',
        state:'未支付'
      }]
    }
  },
  methods: {
    order() {
      this.$router.replace('/my_info/myorder/unpay/detail_unpay');
      //send the message to back-end
      console.log("unpay");
    }
  }
}
</script>
